// 自动生成模板CasCards
package card

import (
	"github.com/flipped-aurora/gin-vue-admin/server/global"
	"gorm.io/datatypes"
	"time"
)

// casCards表 结构体  CasCards
type CasCards struct {
	global.GVA_MODEL
	No          *string        `json:"no" form:"no" gorm:"column:no;comment:断卡线索编号;size:191;"`                                                           //线索编号
	CaseNo      *string        `json:"caseNo" form:"caseNo" gorm:"column:case_no;comment:案件编号;size:191;"`                                                //案件编号
	Type        *string        `json:"type" form:"type" gorm:"column:type;comment:类型;size:25;" binding:"required"`                                       //类型
	CardId      *string        `json:"cardId" form:"cardId" gorm:"column:card_id;comment:卡号;size:120;" binding:"required"`                               //卡号
	Name        *string        `json:"name" form:"name" gorm:"column:name;comment:开卡人;size:25;" binding:"required"`                                      //开卡人
	IdNumber    *string        `json:"idNumber" form:"idNumber" gorm:"column:id_number;comment:开卡人身份证;size:120;" binding:"required"`                     //身份证
	Phone       *string        `json:"phone" form:"phone" gorm:"column:phone;comment:联系电话;size:55;"`                                                     //联系电话
	OpenAt      *time.Time     `json:"openAt" form:"openAt" gorm:"column:open_at;comment:开卡时间;"`                                                         //开卡时间
	OpenIn      *string        `json:"openIn" form:"openIn" gorm:"column:open_in;comment:开户银行/营业商;size:120;" binding:"required"`                         //开户银行/营业商
	OpenAddress *string        `json:"openAddress" form:"openAddress" gorm:"column:open_address;comment:开户网点;size:120;"`                                 //开户网点
	TownCode    *string        `json:"townCode" form:"townCode" gorm:"column:town_code;comment:归属乡镇;size:25;" binding:"required"`                        //乡镇
	Reason      *string        `json:"reason" form:"reason" gorm:"column:reason;comment:原因;size:100;"`                                                   //原因
	FOwnerId    *int           `json:"fOwnerId" form:"fOwnerId" gorm:"column:f_owner_id;comment:主办人;size:19;"`                                           //主办人
	State       *string        `json:"state" form:"state" gorm:"column:state;comment:处理状态 wait待下发 pending已下发 processed已反馈 finished已上报 move已移交;size:25;"` //状态
	Smite       *string        `json:"smite" form:"smite" gorm:"column:smite;comment:是否惩戒 Y已惩戒 N未惩戒;size:25;"`                                           //惩戒
	Attachments datatypes.JSON `json:"attachments" form:"attachments" gorm:"column:attachments;comment:附件;"swaggertype:"array,object"`                   //附件
	IssueAt     *time.Time     `json:"issueAt" form:"issueAt" gorm:"column:issue_at;comment:下发时间;" binding:"required"`                                   //下发时间
	ExceedAt    *time.Time     `json:"exceedAt" form:"exceedAt" gorm:"column:exceed_at;comment:反馈截止时间;" binding:"required"`                              //截止时间
	// 在结构体中新增如下字段
	Address *string `json:"address" form:"address" gorm:"column:address;comment:居住地址;"` //居住地址
}

// TableName casCards表 CasCards自定义表名 cas_cards
func (CasCards) TableName() string {
	return "cas_cards"
}
